<template>
	<view class="content">
		<view class="panel-header solids-bottom padding-bottom-xs">
			<text class="panel-title text-xl text-bold">教育经历</text>
		</view>
		<view class="panel-content">
			<view v-for="(item,index) in educationExperience" :key="index">
				<view class="flex text-lg padding-sm text-left border-bottom">
					<view class="action">
						<view class="flex text-bold word-warp text-left">{{item.school}}</view>
					</view>
				</view>
				<view class="padding-left-xs padding-right-xs">
					<view class="panel-item flex text-lg padding-sm text-left border-bottom">
						<view class="basis-30">起止时间:</view>
						<view class="basis-70">
							<view>{{item.end != "至今" ? item.start + " 至 " + item.end : item.start + " " + item.end}}
							</view>
						</view>
					</view>
					<view class="panel-item flex text-lg padding-sm text-left border-bottom">
						<view class="basis-30">专业:</view>
						<view class="basis-70">
							<view>{{item.majure}}</view>
						</view>
					</view>
					<view class="panel-item flex text-lg padding-sm text-left border-bottom">
						<view class="basis-30">课程:</view>
						<view class="basis-70">
							<view class="word-warp">{{item.lecture}}</view>
						</view>
					</view>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				eduExperienceEdit: false,
				educationExperience: []
			}
		},
		created() {},
		methods: {},
		props: ['external_data'],
		watch: {
			external_data: {
				handler(val, oldVal) {
					this.educationExperience = val;
				},
				deep: true
			}
		}
	}
</script>

<style>
	.panel {
		/* width: 100%; */
		margin: 10px;
		padding: 10px;
		height: auto;
	}

	.panel-header {
		display: flex;
		flex-direction: row;
		align-items: baseline;
		justify-content: space-between;
	}

	.word-warp {
		word-wrap: break-word;
		word-break: break-all;
		overflow: hidden;
	}

	.border-bottom {
		border-bottom: #eeeeee solid 1px;
	}

	.basis-30 {
		flex-basis: 30%;
	}

	.basis-70 {
		flex-basis: 70%;
	}
</style>
